package 落谷.数组;

import java.util.Scanner;

/**
 * P1428小鱼比可爱
 *
 * @author yang
 * @date 2021/12/23
 */
public class P1428小鱼比可爱 {

    static int N = 110;
    static int n;
    static int[] a = new int[N];
    static int[] t = new int[N];

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        n = sc.nextInt();
        for (int i = 0; i < n; i++) {
            a[i] = sc.nextInt();
            for (int j = 0; j < i; j++) {
                if (a[j] < a[i]) t[i]++;
            }
        }
        for (int i = 0; i < n; i++) {
            System.out.printf("%d ",t[i]);
        }
    }
}
